package org.bright.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import static org.springframework.web.bind.annotation.RequestMethod.POST;

@Controller
@ResponseBody
public class BookController {

    @RequestMapping(value = "add",method = POST)
    public String sayHello1() throws InterruptedException {

        System.out.println("新增");
        return "新增";
    }
    @RequestMapping("update")
    public String sayHello2(){

        System.out.println("修改");
        return "修改";
    }
    @RequestMapping("delete")
    public String sayHello3() throws InterruptedException {

        System.out.println("删除");
        return "删除";
    }
    @RequestMapping("select")
    public String sayHello4() throws InterruptedException {

        System.out.println("查询");
        return "查询";
    }

}
